home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus 1995 #5 & #6 / Amiga Plus CD - 1995 - No. 5 and 6.iso / pd / spiele / gnuchess / src / doc / readme.font < prev    next >
Text File  |  1995-07-02  |  10KB  |  204 lines

  1. PostScript Chess Font -- "README" file.
  2. ========== ===== ==== == ======== =====
  3.  
  4.     Copyright (c) 1991 A. N. Walker.  All rights reserved.
  5.  
  6. Restrictions on Use:
  7. ------------ -- ----
  8.     You must keep the copyright notice on this file and on the
  9. accompanying "Font" file.  If you change anything, you must clearly
  10. mark your changes.  Otherwise, you may use these files as you please
  11. for private, educational or research purposes.  You may also use them
  12. freely for commercial purposes as long as you do not make any changes
  13. to the shapes of the pieces without my approval.
  14.  
  15.     I do not, and am in no position to, make any claim as to
  16. suitability of these files for any specific purpose.  They work for
  17. me, and if they work for you too I shall be pleased.  If they do not
  18. work for you, well, you have what you paid for.
  19.  
  20.     If you are pleased with the results, please let me [and your
  21. readers, if any!] know.  If you manage to make money out of them,
  22. please let me know how!  I'd quite like to see [real or PostScript]
  23. copies of what you manage to do, if you have the necessary time,
  24. inclination and resources.
  25.  
  26.     If you don't like the results, please let me know why.  Indeed,
  27. if you have any comments, please e- or snail- mail them to me.
  28.  
  29. What you have to do:
  30. ---- --- ---- -- ---
  31.     You should have three files, called "Font", "Demo" and "Table".
  32. If you have a way of viewing PostScript, shovel "Font" and "Demo" or
  33. "Font" and "Table" at it;  for example, I use the commands
  34.  
  35.         lpr -Plwriter Font Demo
  36.         lpr -Plwriter Font Table
  37.  
  38. to see the results on "my" LaserWriter.  If you have no way of viewing
  39. PostScript, then I'm sorry, but I can't help you.  What you should see
  40. is an assorted collection of boards and figurines in various sizes and
  41. rotations ("Demo") or a neat table showing all the symbols in the font
  42. ("Table").  If anything else happens, you will have to consult someone
  43. who knows what they're doing -- *not* me!  I can promise you that the
  44. files as shipped print nicely on a bog-standard Apple LW+.  They take
  45. several minutes each to print on our LW+;  this is largely because they
  46. make almost pessimal use of the font caching mechanism -- lots of big
  47. characters are printed once each in different sizes and orientations.
  48. Conventional pages with lots of figurines or ordinary text and only a
  49. few diagrams print acceptably quickly (especially, of course, if you
  50. have a faster or more recent LW).
  51.  
  52.     If you are happy with the demos, you can then install the "Font"
  53. file as a font in your system.
  54.  
  55.     ****************************************
  56.     * I cannot help you with this process! *
  57.     ****************************************
  58.  
  59. I can't even do it for our own computer, which has a much-hacked (from
  60. its PDP-11 days) version of Troff;  I leave it to our guru.  Neither
  61. he nor I know what magic you have to utter for an unhacked Troff, or
  62. for TEX, or for Macs or PCs or whatever weird and wonderful software
  63. or hardware you possess.  When you install the font, you may also find
  64. it useful to grab some of the PostScript code from "Demo", especially
  65. if you want to draw (for example) labelled diagrams.
  66.  
  67. What there is in the Font:
  68. ---- ----- -- -- --- -----
  69.     There are really two fonts wrapped up into one.  The more
  70. conventional sub-font is the so-called "text mode", and is what you
  71. get when you first select the font.  This mode itself has two major
  72. components.  The upper case letters are the figurines, for use in
  73. text.  For example, "Q" draws a queen figurine.  Lower case letters
  74. and other symbols are (most of) the Informant symbols (omitting only
  75. symbols like "?" and "ch" that you can reasonably expect to find in
  76. boring old Times Roman, but including "+" and "-").  I've been as
  77. mnemonic as I could, but there are just too many symbols.
  78.  
  79.     The other sub-font is "diagram mode".  In this, upper case
  80. letters draw white pieces, and lower case letters draw black pieces.
  81. For example, "Knk" draws a white king adjacent to a black knight
  82. and a black king.  The pieces include a selection of fairy pieces
  83. and other related symbols -- everything I've seen or had reported
  84. to me on chess diagrams in the last few years.  The other symbols
  85. in this sub-font consist of board-drawing components and motions
  86. to facilitate the construction of diagrams.  You switch between
  87. text and diagram modes using the prime symbol, "'".  For example,
  88. the famous Reti study can be diagrammed by the PostScript:
  89.  
  90.         ('#[7K;8;k1P;7p;8;8;8;8]') show
  91.  
  92. where "#" draws the board, and the stuff between "[...]" is the
  93. conventional Forsythe notation for the position.  Obviously, for
  94. practical use, you will need a chess pre-processor (which I have
  95. *not* written!).
  96.  
  97.     Most of the capabilities of the font are illustrated on
  98. the demo page, which also includes some possibly-useful PostScript
  99. procedures for various of the effects.
  100.  
  101.     Warning:  the dual-mode font treads on very thin ice in
  102. some places!  In particular, the caching mechanisms of PostScript
  103. are very easy to fool with a dynamic font of this type.  For example,
  104. finding the width of a string is fraught with danger;  do it only
  105. with strings that include matched pairs of primes.
  106.  
  107. The font design:
  108. --- ---- -------
  109.     There are surprisingly many different chess fonts in use in
  110. printed books.  I have tried to copy the simplest -- for example,
  111. the rooks have no brickwork, and the kings are quite plain.  Note
  112. that the pieces do not scale well.  Large pieces (inches high) for
  113. posters, etc., will have to be specially designed (and are usually
  114. based on "real" Staunton pieces).  Tiny pieces suffer from the lack
  115. of resolution on 300 dpi (or coarser) printers.  On a 300 dpi printer,
  116. 7-point is really too small, anything less is hopeless (see the demo).
  117. I usually use 15-point, which is comparable with most books.
  118.  
  119.     The hardest piece to get right is the knight.  The book designs
  120. are hopeless at 300 dpi resolution, as there are too many fine lines
  121. around the mouth and chin.  Any attempts to copy them just look like a
  122. caricature.  So I've made it a bit chunkier.  Most readers don't notice.
  123.  
  124.     Note that most of the pieces (as opposed to the figurines)
  125. cannot be cached.  This is because they include both write-white and
  126. write-black components (partly, but not entirely, because they have
  127. to work on black squares);  this makes drawing a whole page of black
  128. kings (or whatever) rather slooow.  Fortunately, you don't often need
  129. such a thing.  The figurines *are* cached, so are the Informant symbols,
  130. and so are the commonest pieces (the black squares, and the pawns of
  131. both colours).
  132.  
  133. Foreign usage:
  134. ------- ------
  135.     Foreign users may want to re-assign the letters used for the
  136. various pieces.  This can easily be done in the Font file.  Lines
  137. such as
  138.  
  139.     dup 8#113 /WK put        % 'K'
  140.  
  141. (not too far down the file) signify that ASCII character 113 (octal), or
  142. "K", is to draw the White King.  If you want some other character to draw
  143. the WK, alter the 113 to match.  You will have to change the BK and Kfig
  144. by the same amount, and you will also have to reassign whatever symbol
  145. your chosen character already draws, if any.  Another minor problem is
  146. that some of the fairy pieces are defined explicitly in terms of the
  147. existing pieces -- eg, if you decide to use "F" to draw White queens,
  148. then the procedure for Grasshoppers (look for "WG" in Font) must be
  149. changed to draw upside-down "F" instead of upside-down "Q".  I hope the
  150. necessary edits are obvious even to non-PostScript users.  I suggest that
  151. after any change you try the Table and Demo files again.
  152.  
  153. Unusual chess pieces:
  154. ------- ----- -------
  155.     I've included a fair number of pieces that may not be familiar to
  156. all chess players.  These include:
  157.     F for fou, French version of bishop.  There are several designs
  158.         of fou in print, I have selected the easiest to implement.  If
  159.         you want one of the others, you'll have to write it yourself.
  160.     D,X for draughts pieces.  Note that these are not cached (except
  161.         as figurines);  if you are writing a book on draughts with
  162.         lots of diagrams, you might find it worthwhile to re-write
  163.         them in a cachable way.  This is easier if you want to use
  164.         them on the white squares (you don't need the "halo" effect),
  165.         but the books I have seen are about equally split on this.
  166.     C,I,T for chameleon, imitator, rose.  Various fairy pieces.
  167.     E,G,L,M,O,S,U,V,Z for various rotated standard pieces, used in
  168.         fairy chess.  Note that the "Demo" file includes a more
  169.         general way to rotate a piece.  I have used S for nightrider,
  170.         oppositely to the problemists convention which uses S for
  171.         knight and N for nightrider;  there is no way that the average
  172.         player is going to change his habits!  If you are a problemist,
  173.         feel free to interchange S and N (and then M and Z).
  174.     .,@,|,_ for various other marks useful in annotating diagrams.
  175.         See the "Demo" file for examples of their use.
  176.     A,H,J,W,Y are unused.  Feel free to use them to add new pieces.
  177.  
  178. Go pieces:
  179. -- -------
  180.     Sorry, despite several requests, I haven't put these in.  I
  181. can't save the whole world in one easy lesson.  The pieces themselves
  182. and the board are easy in PostScript;  the annotations and the necessary
  183. pre-processor are another kettle of fish.  The Go stones could also be
  184. used for Reversi (Othello).
  185.  
  186. Bridge symbols:
  187. ------ --------
  188.     No-one has actually asked for these, but just to forestall you,
  189. note that they are already provided in many places -- symbol fonts,
  190. dingbats fonts, Hershey fonts, ....
  191.  
  192. Final comments:
  193. ----- ---------
  194.     Suggestions for improvements, especially in the PostScript,
  195. will be welcomed.  Especially if they improve portability (which I
  196. can't check locally!).  Especially if you've tried them yourself,
  197. and can vouch that they work.  Suggestions for extra symbols (other
  198. than Go or Bridge) also welcomed, especially if accompanied by
  199. PostScript or other descriptions of their shape.
  200.  
  201. -- 
  202. Andy Walker, Maths Dept., Nott'm Univ., UK.
  203. anw@maths.nott.ac.uk
  204.